Digital video systems typically employ one or more graphics processing units (GPU) to process video data. A GPU may be a dedicated graphics and video rendering device for computers, workstations, game consoles, and similar digital processing devices. A GPU is usually implemented as a co-processor component to the central processing unit (CPU) of the computer, and may be provided in the form of an add-in card (e.g., video card), co-processor, or as functionality that is integrated directly into the motherboard of the computer or into other devices (such as, for example, Northbridge devices and CPUs).
One common function of graphics processor units is to process texture information. Texture mapping is a method for adding detail, surface texture, or color to a computer-generated graphic or 3D (three-dimensional) model. In this process, a texture map is applied to the surface of a shape. A texel (texture element or texture pixel) is the fundamental unit of texture space used in computer graphics, and textures are represented by arrays of texels. When texturing a 3D surface, the texture mapping process maps texels to appropriate pixels in the output picture. If a texel is requested that is not on an integer position, a texture filtering process is applied, and if a texel is requested that is outside of the texture, a combination of clamping and wrapping techniques is used. Clamping limits the texel to the texture size, and wrapping moves the texel back into the texture.
Texture filtering governs the way that resulting pixels on the screen are calculated from the texels. In texture filtering, pre-calculated, optimized collections of bitmap images that accompany a main texture, referred to as ‘mipmaps’ are used to increase rendering speed and reduce artifacts. Mipmaps are widely used in many graphics applications such as 3D computer games, flight simulators and other 3D imaging systems.
Each bitmap image of the mipmap set is essentially a version of the main texture, but at a certain reduced level of detail (LOD). Accounting for level of detail involves decreasing the complexity of a 3D object representation as it moves away from the viewer or according other metrics such as object importance, eye-space speed, or position. LOD techniques increase the efficiency of rendering by decreasing the workload on graphics pipeline stages. The reduced visual quality of the model is often unnoticed because of the small effect on object appearance when distant or moving fast. Present graphics APIs (application program interfaces) typically only allow the loading of an entire mipmapped texture at the time it is bound for use in drawing. In present systems, to avoid loading the entire set of mipmaps, the application usually calculates the LOD itself before loading the actual texture. However, this method is generally difficult and inaccurate. It also often results in the loading of mipmap levels and regions that are not required during rendering.
What is desirable, therefore, is an intelligent texture preload method that avoids loading large amounts of a texture image that may never by touched or accessed.
What is further desirable is an LOD and region clamping and usage reporting mechanism that allows an application or driver to manage the amount of texture data to load over time.